<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); ?>
<?php 
	$ci = & get_instance(); 
	$id = $this->input->post('id',0);
?>
<?php if(!$id): ?>
<form action="<?php echo site_url('admin/dataman/general/auction_coin_submit');?>" name="auction_coin_submit" id="auction_coin_submit" method="post" enctype="multipart/form-data" >
	
	<div class="grid2"><span class="bold">*From:</span></div>
	<div class="grid6"><input type="text" maxlength="20" id="from" name="from" value="" class="std-input"/></div>
<div class="clrboth"></div>		
	<div class="grid2"><span class="bold">*To:</span></div>
	<div class="grid6"><input type="text" maxlength="20" id="to" name="to" value="" class="std-input"/></div>
<div class="clrboth"></div>		
	<div class="grid2"><span class="bold">*Coins:</span></div>
	<div class="grid6"><input type="text" maxlength="20" id="coins" name="coins" value="" class="std-input"/></div>	
<div class="clrboth"></div>		
	<div class="grid2"><span class="bold">*Days Accept:</span></div>
	<div class="grid6"><input type="text" maxlength="10" id="days_accept" name="days_accept" value="30" class="std-input"/> </div>
<div class="clrboth"></div>		 
	<div class="grid2">&nbsp;</div>
	<div class="grid6"><input type="submit" class="button" /> <?php echo loader_image('id="loader_image" class="hidden"');?></div>
	<div class="clrboth"></div>	
	<input type="hidden" name="id" id="id" value="0"/>
</form>
<?php else:?>
<form action="<?php echo site_url('admin/dataman/general/auction_coin_submit');?>" name="auction_coin_submit" id="auction_coin_submit" method="post" enctype="multipart/form-data" >
	<?php 
		$PACK = $ci->auction_coupon->init('id', $id); 
	?>
	<div class="grid2"><span class="bold">*From:</span></div>
	<div class="grid6"><input type="text" maxlength="20" id="from" name="from" value="<?php echo $PACK->getFrom();?>" class="std-input"/></div>
<div class="clrboth"></div>		
	<div class="grid2"><span class="bold">*To:</span></div>
	<div class="grid6"><input type="text" maxlength="20" id="to" name="to" value="<?php echo $PACK->getTo();?>" class="std-input"/></div>
<div class="clrboth"></div>		
	<div class="grid2"><span class="bold">*Coins:</span></div>
	<div class="grid6"><input type="text" maxlength="20" id="coins" name="coins" value="<?php echo $PACK->getCoins();?>" class="std-input"/></div>	
<div class="clrboth"></div>		
	<div class="grid2"><span class="bold">*Days Accept:</span></div>
	<div class="grid6"><input type="text" maxlength="10" id="days_accept" name="days_accept" value="<?php echo $PACK->getDaysAccept();?>" class="std-input"/> </div>
<div class="clrboth"></div>		 
	<div class="grid2">&nbsp;</div>
	<div class="grid6"><input type="submit" class="button" /> <?php echo loader_image('id="loader_image" class="hidden"');?></div>
	<div class="clrboth"></div>	
	<input type="hidden" name="id" id="id" value="<?php echo $id;?>"/>
</form>
<?php endif;?>